#include <iostream>

struct Node
{
    Node * right,*down;
    int val;
    Node(Node * right,Node* down ,int val):
    right(right),down(down),val(val) {}
};

class SkipList
{
private:
    Node * head;

public:
    SkipList()
    {
        head = new Node(NULL, NULL,-1);//初始化
    }
    bool search(int target)
    {
        Node * p = head;
        while(p)
        {
            while(p->right && p->right->val > target)
                p = p->right;
            if(!p->right || target< p->right->val)
                p = p->down;
            
        }
    }


};

